package jp.co.toshiba.ffsa.action.csct;

import javax.annotation.Resource;

import jp.co.toshiba.ffsa.action.common.CommonAction;
import jp.co.toshiba.ffsa.form.csct.Csct102Form;

import org.seasar.struts.annotation.ActionForm;
import org.seasar.struts.annotation.Execute;

/**
 * お問い合わせ送信完了
 * @author npc
 */
public class Csct102Action extends CommonAction {

    /** 画面ID */
    public String screenID = "CSCT102";

    @ActionForm
    @Resource
    protected Csct102Form csct102Form;

    /**
     * 初期処理
     * @return 画面遷移先
     */
    @Execute(validator = false)
    public String index() throws Exception{
        // ログイン済判定する
        if(this.judgeLogin(csct102Form.getSessionId())){
            try{
                // リファラ判定
                if(this.judgeRefferer()){
                    return "/csct/csct102.jsp";
                }else{
                    return this.topTransition;
                }
            }catch(Exception e){
                this.errorLogWriter(e, "index", this.screenID);
                throw e;
            }
        }else{
            return this.topTransition;
        }
    }
}